package com.example.hanfu_bk.pojo;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Date;

@AllArgsConstructor
@NoArgsConstructor
@Data
public class User {
    private Integer id;
    private String avatar;
    private String nickname;
    private Integer isLogin; // 引用类型
    private String phone;
    private String password;
    private String favoriteThing;

    // getter和setter方法
    public String getFavoriteThing() {
        return favoriteThing;
    }

    public void setFavoriteThing(String favoriteThing) {
        this.favoriteThing = favoriteThing;
    }

    // 修复：Setter参数改为Integer，支持null
    public void setIsLogin(Integer isLogin) {
        this.isLogin = isLogin;
    }

    public Integer getId() { return id; }
    public void setId(Integer id) { this.id = id; }

    public String getAvatar() { return avatar; }
    public void setAvatar(String avatar) { this.avatar = avatar; }

    public String getNickname() { return nickname; }
    public void setNickname(String nickname) { this.nickname = nickname; }

    public Integer getIsLogin() { return isLogin; } // 补充Getter

    public String getPhone() { return phone; }
    public void setPhone(String phone) { this.phone = phone; }

    public String getPassword() { return password; }
    public void setPassword(String password) { this.password = password; }
}